<template>
  <el-card>
    <h3>系统参数配置</h3>
    <el-table :data="params" style="width: 100%">
      <el-table-column prop="key" label="参数名" />
      <el-table-column prop="value" label="参数值">
        <template slot-scope="scope">
          <el-input v-model="scope.row.value" size="small" />
        </template>
      </el-table-column>
      <el-table-column label="操作">
        <template slot-scope="scope">
          <el-button type="primary" size="mini" @click="saveParam(scope.row)">保存</el-button>
        </template>
      </el-table-column>
    </el-table>
  </el-card>
</template>

<script>
export default {
  name: "Xtcs",
  data() {
    return {
      params: [
        { key: "系统名称", value: "体检管理系统" },
        { key: "最大登录尝试次数", value: "5" },
        { key: "数据刷新间隔(秒)", value: "60" },
      ],
    };
  },
  methods: {
    saveParam(row) {
      this.$message.success(`参数“${row.key}”已保存（模拟）`);
    },
  },
};
</script> 